import UIKit

var fruits = ["苹果","香蕉"]
//添加一个元素
fruits.append("榴莲")
print(fruits)

//添加多个元素
fruits.append(contentsOf: ["橘子","菠萝蜜"])
print(fruits)

fruits+=["西瓜"]
print(fruits)

//添加一个区间
var n = [1,2]
n.append(contentsOf: 4...6)
print(n)
